package main

import (
	"fmt"
	"net/http"
	"time"
)

func main() {
	timeout := time.Duration(3 * time.Second)
	//设置3秒超时
	client := http.Client{
		Timeout: timeout,
	}
	_, err := client.Get("http://49.85.15.144:9000")

	//请求出错或者超时，就更换下一个
	if err != nil {
		fmt.Println("请求出错，或者是响应超时,目标：")
		fmt.Println(">>>开始匿名请求")

	}
}
